//
//  TLTweetDetailViewController.m
//  Coding_iOS
//
//  Created by taolei-mac on 2017/11/30.
//  Copyright © 2017年 com.lianchuan. All rights reserved.
//

#import "TLTweetDetailViewController.h"
#import "TLTweet.h"
#import "TLOwner.h"
#import "TLHttpTool.h"

@interface TLTweetDetailViewController ()

@end

@implementation TLTweetDetailViewController

- (void)viewDidLoad
{
    [super viewDidLoad];
    
    self.title = @"冒泡详情";
    
    self.view.backgroundColor = [UIColor whiteColor];
    
    self.customerNavigationItem.rightBarButtonItem = [UIBarButtonItem itemWithImageName:@"share_Nav" highImageName:@"share_Nav" target:self action:nil];
    
    [self getTweetDetailInfo];
}

- (void)getTweetDetailInfo
{
    NSString *globalKey = self.tweet.owner.global_key;
    
    NSString *url = [NSString stringWithFormat:@"%@%@", @"https://coding.net/api/tweet/", globalKey];
    url = [NSString stringWithFormat:@"%@%@%zd", url, @"/", self.tweet.Id];
    [TLHttpTool get:url params:nil success:^(id responseObj) {
        
        TLLog(@"%@", responseObj);
    } failure:^(NSError *error) {
        
    }];
}

@end
